#include <stdio.h>
#include <stdlib.h>

/* run this program using the console pauser or add your own getch, system("pause") or input loop */

int main(int argc, char *argv[]) {
	int s,a,b,c;
	for(s=100;s<=999;s++){
		a = s/100;
		b = (s%100)/10;
		c = s%10;
		if(s==a*a*a+b*b*b+c*c*c){
			printf("%d\n",s);
		}
	}
	return 0;
}
